Optimal. Leaf size=81 \[ \frac{\cot (e+f x) \sqrt{a \sec (e+f x)+a}}{a c f}-\frac{\tan ^{-1}\left (\frac{\sqrt{a} \tan (e+f x)}{\sqrt{2} \sqrt{a \sec (e+f x)+a}}\right )}{\sqrt{2} \sqrt{a} c f} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.231719, antiderivative size = 116, normalized size of antiderivative = 1.43, number of steps used = 4, number of rules used = 4, integrand size = 36, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.111, Rules used = {3964, 78, 63, 208} \[ -\frac{\tan (e+f x)}{f \sqrt{a \sec (e+f x)+a} (c-c \sec (e+f x))}-\frac{\tan (e+f x) \tanh ^{-1}\left (\frac{\sqrt{c-c \sec (e+f x)}}{\sqrt{2} \sqrt{c}}\right )}{\sqrt{2} \sqrt{c} f \sqrt{a \sec (e+f x)+a} \sqrt{c-c \sec (e+f x)}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3964
Rule 78
Rule 63
Rule 208
Rubi steps
\begin{align*} \int \frac{\sec ^2(e+f x)}{\sqrt{a+a \sec (e+f x)} (c-c \sec (e+f x))} \, dx &=-\frac{(a c \tan (e+f x)) \operatorname{Subst}\left (\int \frac{x}{(a+a x) (c-c x)^{3/2}} \, dx,x,\sec (e+f x)\right )}{f \sqrt{a+a \sec (e+f x)} \sqrt{c-c \sec (e+f x)}}\\ &=-\frac{\tan (e+f x)}{f \sqrt{a+a \sec (e+f x)} (c-c \sec (e+f x))}+\frac{(a \tan (e+f x)) \operatorname{Subst}\left (\int \frac{1}{(a+a x) \sqrt{c-c x}} \, dx,x,\sec (e+f x)\right )}{2 f \sqrt{a+a \sec (e+f x)} \sqrt{c-c \sec (e+f x)}}\\ &=-\frac{\tan (e+f x)}{f \sqrt{a+a \sec (e+f x)} (c-c \sec (e+f x))}-\frac{(a \tan (e+f x)) \operatorname{Subst}\left (\int \frac{1}{2 a-\frac{a x^2}{c}} \, dx,x,\sqrt{c-c \sec (e+f x)}\right )}{c f \sqrt{a+a \sec (e+f x)} \sqrt{c-c \sec (e+f x)}}\\ &=-\frac{\tan (e+f x)}{f \sqrt{a+a \sec (e+f x)} (c-c \sec (e+f x))}-\frac{\tanh ^{-1}\left (\frac{\sqrt{c-c \sec (e+f x)}}{\sqrt{2} \sqrt{c}}\right ) \tan (e+f x)}{\sqrt{2} \sqrt{c} f \sqrt{a+a \sec (e+f x)} \sqrt{c-c \sec (e+f x)}}\\ \end{align*}
Mathematica [A] time = 0.473784, size = 73, normalized size = 0.9 \[ -\frac{\cot \left (\frac{1}{2} (e+f x)\right ) \left (\sqrt{2} \sqrt{\sec (e+f x)-1} \tan ^{-1}\left (\frac{\sqrt{\sec (e+f x)-1}}{\sqrt{2}}\right )-2\right )}{2 c f \sqrt{a (\sec (e+f x)+1)}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.238, size = 204, normalized size = 2.5 \begin{align*} -{\frac{1}{2\,fca \left ( \left ( \cos \left ( fx+e \right ) \right ) ^{2}-1 \right ) }\sqrt{{\frac{a \left ( 1+\cos \left ( fx+e \right ) \right ) }{\cos \left ( fx+e \right ) }}} \left ( \left ( \cos \left ( fx+e \right ) \right ) ^{2}\ln \left ( -{\frac{1}{\sin \left ( fx+e \right ) } \left ( -\sqrt{-2\,{\frac{\cos \left ( fx+e \right ) }{1+\cos \left ( fx+e \right ) }}}\sin \left ( fx+e \right ) +\cos \left ( fx+e \right ) -1 \right ) } \right ) \sqrt{-2\,{\frac{\cos \left ( fx+e \right ) }{1+\cos \left ( fx+e \right ) }}}+2\,\cos \left ( fx+e \right ) \sin \left ( fx+e \right ) -\ln \left ( -{\frac{1}{\sin \left ( fx+e \right ) } \left ( -\sqrt{-2\,{\frac{\cos \left ( fx+e \right ) }{1+\cos \left ( fx+e \right ) }}}\sin \left ( fx+e \right ) +\cos \left ( fx+e \right ) -1 \right ) } \right ) \sqrt{-2\,{\frac{\cos \left ( fx+e \right ) }{1+\cos \left ( fx+e \right ) }}} \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \begin{align*} -\int \frac{\sec \left (f x + e\right )^{2}}{\sqrt{a \sec \left (f x + e\right ) + a}{\left (c \sec \left (f x + e\right ) - c\right )}}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 0.549708, size = 676, normalized size = 8.35 \begin{align*} \left [\frac{\sqrt{2} a \sqrt{-\frac{1}{a}} \log \left (\frac{2 \, \sqrt{2} \sqrt{\frac{a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \sqrt{-\frac{1}{a}} \cos \left (f x + e\right ) \sin \left (f x + e\right ) + 3 \, \cos \left (f x + e\right )^{2} + 2 \, \cos \left (f x + e\right ) - 1}{\cos \left (f x + e\right )^{2} + 2 \, \cos \left (f x + e\right ) + 1}\right ) \sin \left (f x + e\right ) + 4 \, \sqrt{\frac{a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right )}{4 \, a c f \sin \left (f x + e\right )}, \frac{\sqrt{2} \sqrt{a} \arctan \left (\frac{\sqrt{2} \sqrt{\frac{a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right )}{\sqrt{a} \sin \left (f x + e\right )}\right ) \sin \left (f x + e\right ) + 2 \, \sqrt{\frac{a \cos \left (f x + e\right ) + a}{\cos \left (f x + e\right )}} \cos \left (f x + e\right )}{2 \, a c f \sin \left (f x + e\right )}\right ] \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} - \frac{\int \frac{\sec ^{2}{\left (e + f x \right )}}{\sqrt{a \sec{\left (e + f x \right )} + a} \sec{\left (e + f x \right )} - \sqrt{a \sec{\left (e + f x \right )} + a}}\, dx}{c} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]